{{#d-modal-body}}
  {{input
    value=(readonly filter)
    input=(action "onFilterChanged" value="target.value")
    class="filter"
    placeholderKey="discourse_post_event.invitees_modal.filter_placeholder"
  }}
  {{toggle-invitees-modal modal=this toggle=(action "toggleType")}}
  {{#conditional-loading-spinner condition=isLoading}}
    {{#if invitees}}
      <ul class="invitees">
        {{#each invitees as |invitee|}}
          <li class="invitee">
            {{render-invitee invitee}}

            {{#if invitee.status}}
              <span class="status {{invitee.status}}">
                {{i18n (concat "discourse_post_event.models.invitee.status." invitee.status)}}
              </span>
            {{else}}
              <span class="status">
                -
              </span>
            {{/if}}

            {{#if model.can_act_on_discourse_post_event}}
              {{d-button
                icon="trash-alt"
                action=(action "removeInvitee" invitee)
              }}
            {{/if}}
          </li>
        {{/each}}
      </ul>
    {{else}}
      <p class="no-users">
        {{i18n "discourse_post_event.models.invitee.no_users"}}
      </p>
    {{/if}}
  {{/conditional-loading-spinner}}
{{/d-modal-body}}
